Title: Year 12 / Computer Science / Theory / 5 - System Software / 5.2 - Language Translators

Q: Describe the purpose of assembler software
A: software that translates assembly language statements into machine code for execution, the mnemonics used translate into machine opcodes, process simple because assembly language has one to one relationship with machine code

Q: Describe the purpose of compilers
A: software that translates a high level language program into machine code

Q: Describe the drawbacks of compilers
A: reports errors at the end of compilation, difficult to locate errors, development process is long, can only be used when all errors are fixed, can only be used when development is complete

Q: Describe the benefits of compilers
A: creates a exe file which can be easily distributed, once compiled the exe file doesnt have to be compiled again, resulting in faster execution

Q: Describe the purpose of interpreters
A: translates and executes a high level language program line by line

Q: Describe the drawbacks of using interpreters
A: no exe file gets created, execution is very slow as program gets translated each time it runs

Q: Describe the benefits of using interpreters
A: debugging is easier and faster, since it stops translating when it reaches an error, which allows real time error correction, can run program any time, even before code is finished, can be used during development

Q: State and explain an example of a language that may be partially compiled and partially interpreted
A: Java programs require 2 step translation, partially compiled then partially interpreted, java code is first translated to bytecode by a java compiler, then the byte code is interpreted by the java virtual machine to produce machine code

Q: State 4 examples of IDE features
A: coding, initial error detection, presentation, debugging

Q: Explain the coding feature of IDEs
A: it has context sensitive prompts, displays keywords and available identifiers appropriate at current insertion point listed in alphabetical order, highlights undeclared/unassigned variable identifiers

Q: Explain the "initial error detection" feature of IDEs
A: it has dynamic syntax checks, which is automatic checking and highlighting of syntax errors as soon as a line is typed, it also has type checking and parameter checking

Q: Explain the "presentation" feature of IDEs
A: prettyprint, which is automatic indentation and color coding of keywords, expand and collapse code blocks, saves excessive scrolling and easy to see global variable declarations and main program body when collapsed

Q: Explain the "debugging" feature of IDEs
A: single stepping, executes program line by line to see effect of each statement on variables, breakpoints which pause programs at specific line to ensure program operates correctly till that line, variables report window which monitors variables for comparing values